//
//  chaoniController.m
//  IOS 开发
//
//  Created by blue on 15-11-6.
//  Copyright (c) 2015年 tangchao. All rights reserved.
//

#import "chaoniController.h"

@interface chaoniController ()
{
    NSArray * data;
    NSArray * detail;
    NSArray* headers;

}
@end

@implementation chaoniController

- (id)initWithNibName:(NSString *)nibNameOrNil bundle:(NSBundle *)nibBundleOrNil
{
    self = [super initWithNibName:nibNameOrNil bundle:nibBundleOrNil];
    if (self) {
        // Custom initialization
    }
    return self;
}

- (void)viewDidLoad
{
    [super viewDidLoad];
    // Do any additional setup after loading the view.
 self.title =@"第二标题栏";
    data =@[
            @"超人",
            @"白风",
            @"安弟"
            ];
     detail=@[
         @"1",
         @"2",
         @"3"
         ];

    headers=@[@"A",
              @"B",
              @"C"
              ];
    
}
-(NSInteger)tableView:(UITableView *)tableView numberOfRowsInSection:(NSInteger)section{
    return data.count;
}

-(UITableViewCell * )tableView:(UITableView *)tableView cellForRowAtIndexPath:(NSIndexPath *)indexPath{
    UITableViewCell * cell=[[UITableViewCell alloc]initWithStyle:UITableViewCellStyleSubtitle
        reuseIdentifier:nil];
    cell.textLabel.text=data[indexPath.section][indexPath.row];
    //    cell.textLabel.text=data[indexPath.row];
cell.accessoryType=UITableViewCellAccessoryDisclosureIndicator;

    
    return cell;
}
- (void)tableView  :(UITableView *)tableView
didSelectRowAtInddexPath:(NSIndexPath *)indexPath{
    [tableView deselectRowAtIndexPath:indexPath animated:YES];
    }

-(BOOL)tableView:(UITableView *)tableView
    canMoveRowAtIndexPath:(NSIndexPath *)indexPath
{
    return YES;

}
-(void)tableView:(UITableView *)tableView commitEditingStyle:(UITableViewCellEditingStyle)editingStyle forRowAtIndexPath:(NSIndexPath *)indexPath
{



}

- (void)didReceiveMemoryWarning
{
    [super didReceiveMemoryWarning];
    // Dispose of any resources that can be recreated.
}

/*
#pragma mark - Navigation

// In a storyboard-based application, you will often want to do a little preparation before navigation
- (void)prepareForSegue:(UIStoryboardSegue *)segue sender:(id)sender
{
    // Get the new view controller using [segue destinationViewController].
    // Pass the selected object to the new view controller.
}
*/

@end
